package com.intexh.quickandroid.pay;

import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.ImageView;
import android.widget.TextView;

import com.intexh.quickandroid.R;
import com.intexh.quickandroid.base.BaseActivity;

import butterknife.BindView;
import butterknife.ButterKnife;
import butterknife.OnClick;

public class PaySuccessActivity extends BaseActivity {

    @BindView(R.id.back_iv)
    ImageView backIv;
    @BindView(R.id.go_detail_btn)
    Button goDetailBtn;
    @BindView(R.id.go_home_btn)
    Button goHomeBtn;
    @BindView(R.id.order_no_tv)
    TextView orderNoTv;
    @BindView(R.id.pay_type_tv)
    TextView payTypeTv;
    private String payType;
    private String orderId;

    public static void startActivity(Context context,String payType,String orderId){
        Intent intent =new Intent(context,PaySuccessActivity.class);
        intent.putExtra("payType",payType);
        intent.putExtra("orderId",orderId);
        context.startActivity(intent);
    }

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_paysucces);
        ButterKnife.bind(this);
        payType = getIntent().getStringExtra("payType");
        orderId = getIntent().getStringExtra("orderId");
        payTypeTv.setText("支付方式："+payType);
        orderNoTv.setText("订单号："+orderId);
    }

    @OnClick({R.id.back_iv, R.id.go_detail_btn, R.id.go_home_btn})
    public void onViewClicked(View view) {
        switch (view.getId()) {
            case R.id.back_iv:
                finish();
                break;
            case R.id.go_detail_btn:
                break;
            case R.id.go_home_btn:

                break;
        }
    }
}
